package com.ruoyi.system.service.impl;
import com.ruoyi.common.core.text.Convert;
import com.ruoyi.system.domain.SysNoticeAttachment;
import com.ruoyi.system.mapper.ISysNoticeAttachmentMapper;
import com.ruoyi.system.service.ISysNoticeAttachmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 通知附件服务实现
 *
 * @author ruoyi
 */
@Service
public class SysNoticeAttachmentServiceImpl implements ISysNoticeAttachmentService {
    @Autowired
    private ISysNoticeAttachmentMapper noticeAttachmentMapper;

    @Override
    public int insertNoticeAttachment(SysNoticeAttachment attachment) {
        return noticeAttachmentMapper.insertNoticeAttachment(attachment);
    }

    @Override
    public int deleteNoticeAttachmentById(Long attachmentId) {
        return noticeAttachmentMapper.deleteNoticeAttachmentById(attachmentId);
    }

    @Override
    public int deleteNoticeAttachmentByNoticeId(Long noticeId) {
        return noticeAttachmentMapper.deleteNoticeAttachmentByNoticeId(noticeId);
    }

    @Override
    public int updateNoticeAttachment(SysNoticeAttachment attachment) {
        return noticeAttachmentMapper.updateNoticeAttachment(attachment);
    }

    @Override
    public SysNoticeAttachment selectNoticeAttachmentById(Long attachmentId) {
        return noticeAttachmentMapper.selectNoticeAttachmentById(attachmentId);
    }

    @Override
    public List<SysNoticeAttachment> selectNoticeAttachmentByNoticeId(Long noticeId) {
        return noticeAttachmentMapper.selectNoticeAttachmentByNoticeId(noticeId);
    }

    @Override
    public List<SysNoticeAttachment> selectNoticeAttachmentList(SysNoticeAttachment attachment) {
        return noticeAttachmentMapper.selectNoticeAttachmentList(attachment);
    }
}
